package mapper;


import com.alibaba.dubbo.config.annotation.Service;
import com.lagou.entity.UserCourseOrder;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Service
public interface OrderDao {

    // 新增订单
    void saveOrder(@Param("orderNo")String orderNo,@Param("user_id")String user_id,@Param("course_id")String course_id,@Param("activity_course_id")String activity_course_id,@Param("source_type")String source_type);

    //更新订单状态
    Integer updateOrder( @Param("orderNo") String orderNo, @Param("status") int status );

    //  删除订单
    Integer deleteOrder(@Param("orderNo") String orderNo);

    //查询登录用户的全部订单
    List<UserCourseOrder> getOrdersByUserId(@Param("userId") String userId);

}
